var userStr = sessionStorage.getItem('user');
var user;
if (userStr){
    user = JSON.parse(userStr);
}else {
    window.location.href = '/login.html';
}

var baseUrl = "http://localhost:8088";

$.get(baseUrl+'/sessions',function (data) {
    if (data.user==null){
        window.location.href = '/login.html';
    }
})